package com.fc.advbox.config;

import org.apache.http.client.HttpClient;
import org.apache.http.impl.client.HttpClients;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import java.util.concurrent.Executor;
import java.util.concurrent.Executors;

/**
 * Created by E7450 on 2018/6/19.
 */
@Configuration
public class AppConfig {

    @Bean
    public HttpClient httpClient()
    {
        return HttpClients.createDefault();
    }

    @Bean
    public Executor executor()
    {
        return Executors.newSingleThreadExecutor();
    }
}
